﻿using System;
using System.Windows.Forms;
using Autodesk.Revit.UI;
using YJKSparseDisOfDoor.ModelLayer;
using YJKRoomInspection.Utiltiy;
using YJKInspectModelFunc.ControlLayer;
using YJKInspectModelFunc.ModelLayer;

namespace YJKSparseDisOfDoor.ControlLayer
{
	internal class LoopMangerNoneSwitch_EvacuationDoorDisDetection : BaseLoopMangerNoneSwitch
	{
		public LoopMangerNoneSwitch_EvacuationDoorDisDetection(UIDocument inputUiDoc, IModelessFormNoneSwitch inputForm, IWin32Window inputParentHandle = null, PickObjectMethod inputPickMethod = null) : base(inputUiDoc, inputForm, inputParentHandle, inputPickMethod)
		{
		}

		protected override void DoBeforeContinue()
		{
			LocationAWayBean tempLocationAWayBean = (this.m_useForm as ResultForm).TempLocationAWayBean;
			if (tempLocationAWayBean != null)
			{
				Utility.ZoomEntiy(tempLocationAWayBean.UseUIDoc, tempLocationAWayBean.UseBean, tempLocationAWayBean.UseForm, tempLocationAWayBean.IfStartDoor);
			}
		}

		protected override void DoAfterWhile()
		{
			Utility.AddValue(StaticRescource.CmdData.Application.ActiveUIDocument, this.m_useForm as ResultForm);
		}
	}
}
